home *** CD-ROM | disk | FTP | other *** search
- /***********************************************************************************
- CExpanderHeader.h
-
- Copyright © 1994 B-Ray Software. All rights reserved.
- Developed using Symantec C++ 7.0.2 and Symantec's TCL library.
- Portions of this code courtesy Symantec, Inc.
-
- This code may be freely distributed as long as this notice remains. This code
- may not be used in any commercial software without the consent of B-Ray Software.
-
- ---
-
- Header file for CExpanderHeader class.
-
- ***********************************************************************************/
- #pragma once
-
- #include "CExpanderPane.h"
- #include "CExpanderLabel.h"
- #include "CExpanderButton.h"
-
-
- class CExpanderHeader : public CExpanderPane {
-
- TCL_DECLARE_CLASS
-
- private:
- CExpanderButton *itsButton;
- CExpanderLabel *itsLabel;
-
- protected:
- virtual void MakeComponents( void );
- virtual void MakeExpanderButton( void );
- virtual CExpanderLabel *MakeExpanderLabel( void );
-
- public:
-
- static const short kExpanderButtonSize;
-
- CExpanderHeader();
- CExpanderHeader( CView *anEnclosure, CBureaucrat *aSupervisor,
- short aWidth = 0, short aHeight = 0, short aHLoc = 0, short aVLoc = 0,
- SizingOption aHSizing = sizFIXEDSTICKY,
- SizingOption aVSizing = sizFIXEDSTICKY );
- virtual ~CExpanderHeader();
-
- /*
- * Label access routines
- */
- virtual void SetTitle( Str255 aText )
- { itsLabel->SetText( aText ); };
- virtual void GetTitle( Str255 buffer )
- { itsLabel->GetText( buffer ); };
-
- virtual void SetLabelSelectable( Boolean aFlag )
- { itsLabel->SetCanSelect( aFlag ); };
- virtual Boolean GetLabelSelectable( void )
- { return itsLabel->CanSelect(); };
-
- virtual void SetDblClickCmd( long theCommand )
- { itsLabel->SetDblClickCmd( theCommand ); };
- virtual long GetDblClickCmd( void )
- { return itsLabel->GetDblClickCmd(); };
-
- /*
- * Button access routines
- */
- virtual void SetButtonValue( Boolean value )
- { itsButton->SetValue( value ); };
- virtual Boolean GetButtonValue( void )
- { return itsButton->GetValue(); };
-
- virtual void SetButtonEnabled( Boolean value )
- { itsButton->SetEnabled( value ); };
- virtual Boolean GetButtonEnabled( void )
- { return itsButton->GetEnabled(); };
-
- /*
- * Stream methods
- */
- virtual void PutTo( CStream &stream );
- virtual void GetFrom( CStream &stream );
-
- #ifdef NEVER
- friend CStream& operator << ( CStream &s, CExpanderHeader *p )
- { return PutObject( s, p ); };
- friend CStream& operator >> ( CStream &s, CExpanderHeader*& p)
- { return GetObject( s, p ); };
- #endif
-
- };
-
-
-